package com.lingchen.boot.gof.chart;

import java.util.Scanner;

/**
 * Created by lc on 2020/6/22
 */
public class TestChart {
    private static AbstractChart abstractChart;

    public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);
        String clzName = sc.nextLine();

        setAbstractChart(clzName);

        abstractChart.display();

    }

    public static void setAbstractChart(String name) throws Exception {
        abstractChart = (AbstractChart)Class.forName(name).newInstance();
    }
}
